import request from '@/utils/request'
// 采购员
// /purchase/purchaser/list?size=5&current=1
export function getbuyerAll(data){
  return request({
    url:"/purchase/purchaser/list?size=125&current=1",
    method:"post",
    data
  })
}

// /purchase/purchaser/add
// {"name":"赵云", "code": "004", "phone": 123, "remarks": "王牌采购", "wsId": 1}
export function addbuyer(data){
  return request({
    url:"/purchase/purchaser/add",
    method:"post",
    data
  })
}

// /purchase/purchaser/del/1
export function delbuyer(id,data){
  return request({
    url:"/purchase/purchaser/del/"+id,
    method:"post",
    data
  })
}

// /purchase/purchaser/edit
export function editbuyer(data){
  return request({
    url:"/purchase/purchaser/edit",
    method:"post",
    data
  })
}
export function changeBuyerStatus(data){
  return request({
    url:"/purchase/purchaser/state",
    method:"post",
    data
  })
}

// 获取所有的用户状态值
export function getstatusenum(){
  return request({
    url:"/purchase/purchaser/state/enum",
    method:"get"
  })
}

// 获取供应商的详情
export function getPurchaserInfo(data){
  return request({
    url:"/purchase/purchaser/detail",
    method:"post",
    data
  })
}


// 获取所有的用户列表
export function bindsysuser(data){
  return request({
    url:"/purchase/purchaser/bind",
    method:"post",
    data
  })
}
